package library.model;

/**
 * @author Dmitry
 */
public class DownloadFilePojo {
    private int id;
    private String file;
    private int status = 0;
    private String message;
    private boolean error = false;
    private String author;

    public DownloadFilePojo(String file) {
        this.file = file;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }
    
    

    public boolean isError() {
        return error;
    }

    public void setError(boolean error) {
        this.error = error;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getFile() {
        return file;
    }

    public void setFile(String file) {
        this.file = file;
    }

    public int getStatus() {
        synchronized (this) {
            return status;
        }
    }

    public void setStatus(int status) {
        synchronized (this) {
            this.status = status;
        }
    }

    @Override
    public int hashCode() {
        int hash = 7;
        hash = 43 * hash + id;
        return hash;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final DownloadFilePojo other = (DownloadFilePojo) obj;
        if (this.id != other.id) {
            return false;
        }
        return true;
    }
}
